package com.nsoft.html5npub.objects;

import android.content.Context;
import android.util.AttributeSet;
import android.view.MotionEvent;
import android.widget.VideoView;

public class MaskVideoView extends VideoView {
	
	public MaskVideoView(Context c){
		super(c);
	}
	
	public MaskVideoView(Context c,AttributeSet attrs) {
		super(c,attrs);
	}

	
	
	@Override
	public boolean onTouchEvent(MotionEvent ev) {
		int touchType=ev.getAction()&
				MotionEvent.ACTION_MASK;
		
		if (touchType==MotionEvent.ACTION_DOWN){
			if (isPlaying()){
				pause();
			}else{
				start();
			}
		}
		return false;
	}
}
